<template>
	<view class="state-navigation">
		<view class="slim_header_navigation d-flex a-center j-center" >
		    <view class="left_box" @tap="goBack">
		        <image src="/static/center/back.png" class="back"></image>
		    </view>
		    <view class="title">说明</view>
		    <view class="right_box">
				<!-- <view class="navigation-illustrate" @click="goTransaction()">明细</view> -->
		        <!-- <image src="/static/center/dian.png" class="dian"></image> -->
		    </view>
		</view>
	</view>
	<view class="piece">
		<view class="desp-content">

            <view class="title">Q1：提现到账时间？</view>
            <view class="desp">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;一般情况下，在工作日，到账时间为12小时内。非工作日24小时内到账。</view>

            <view class="title">Q2：提现手续费？</view>
            <view class="desp">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;每笔提现订单收取基础1元+金额×{{txFee}}%的手续费。</view>

            <view class="title">Q3：实名认证</view>
            <view class="desp">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;用户提现时，必须先实名认证，且使用和实名认证相同的支付宝账号进行提现。</view>
		</view>
	</view>
</template>
<script setup lang="tsx" name="serve">
import { ref,computed } from "vue";
import { onShow } from "@dcloudio/uni-app";
import { getWallet,getTradeConfig } from "@/api/api";
import { centToYuan } from "@/utils/format";
import { userData as userDataStore } from "@/store/userData";
const goBack = () => {
	uni.navigateBack();
};
//跳转交易记录页面
const goTransaction = () => {
	uni.navigateTo({
		url:`/pages/transaction/transaction`
	});
};
//跳转交易记录页面
const goCashOut = () => {
	uni.navigateTo({
		url:`/pages/cashOut/cashOut`
	});
};
let walletInfo: any = ref({});
let tradeConfig:any = ref({})
const userData: any = userDataStore();
onShow(async () => {
	await getWallet({userId:userData.id}).then((res: any) => {
		walletInfo.value = res.data
	});
	await getTradeConfig().then((res: any) => {
		tradeConfig.value = res.data
	});
});
const txFee:any = computed(()=>{
	if(tradeConfig.value.txFee1){
		return centToYuan(tradeConfig.value.txFee1)
	}else{
		return ''
	}
})
</script>

<style lang="scss" scoped>
@import './serve.scss';
.desp-content{
	position:relative;
	background: #ffffff;
	border-radius: 10rpx;
    overflow: hidden;
    padding: 30rpx 0 50rpx 0;
    .title{
        font-size:28rpx;
        color:#333;
        font-weight:600;
        margin-top:40rpx;
        padding:0 30rpx;
    }
    .desp{
        font-size:28rpx;
        color:#333;
        padding:0 30rpx;
    }
}
</style>
